import request from '@/utils/request'
import { parseStrEmpty } from "@/utils/ruoyi";

// 查询用户列表
export function listGroup(query) {
  return request({
    url: '/api/SysMemberGroup/index',
    method: 'get',
    params: query
  })
}

// 查询用户详细
export function getGroup(userId) {
  return request({
    url: '/api/SysMemberGroup/show/id/' + parseStrEmpty(userId),
    method: 'get'
  })
}

// 新增用户
export function addGroup(data) {
  return request({
    url: '/api/SysMemberGroup/save',
    method: 'post',
    data: data
  })
}

// 修改用户
export function updateGroup(data) {
  return request({
    url: '/api/SysMemberGroup/update',
    method: 'post',
    data: data
  })
}

// 删除用户
export function delGroup(userId) {
  return request({
    url: '/api/SysMemberGroup/del/id/' + userId,
    method: 'delete'
  })
}

